Skip to content

Text : Added EllipsizeMode for tail and clip alignment #14660

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

iamAbhi-916
Copy link
Contributor

@iamAbhi-916 iamAbhi-916 commented May 12, 2025

Description

Added EllipsizeMode for tail and clip, for head and middle the behaviour maps to default tail alignment of ellipsis.

DirectWrite does not natively support head and middle truncation in the same way it supports tail.
A custom implementation will be required for the same adding that to backlog.

Type of Change

  • New feature (non-breaking change which adds functionality)

Why

This PR adds functionality to a prop EllipsizeMode particular to windows, this prop is tightly coupled with numberOfLines and adjusts the text alignment based on the ellipsis mode.

Resolves [Add Relevant Issue Here]
#13111

What

Made changes to paragraph.cpp to reflect ellipsis depending on the EllipsizeMode prop, and updating the text layout, text alignment for the same.

Screenshots

Add any relevant screen captures here from before or after your changes.

Testing

tested in playground.

Changelog

Should this change be included in the release notes: indicate yes or no
yes

Add a brief summary of the change to use in the release notes for the next release.

Added EllipsizeMode for tail and clip , for head and middle the behaviour maps to default tail alignment of ellipsis.

Microsoft Reviewers: Open in CodeFlow

@iamAbhi-916 iamAbhi-916 requested a review from a team as a code owner May 12, 2025 11:08
@iamAbhi-916 iamAbhi-916 marked this pull request as draft May 12, 2025 11:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant